<% javascript_tag do %>
  function show_hide_search_form(dictionary_id)
  {
    if($('dictionary_'+dictionary_id.toString()+'_search_form').innerHTML != '')
    {
      $('dictionary_'+dictionary_id.toString()+'_search_form').toggle()
      return false
    }
    else
    {
      if($('search_form'))
        Element.remove('search_form')
      return true
    }
  }
<% end %>

<% content_for :title do %>
  <label>Dictionaries</label>
<% end %>

<% content_for :subtitle do %>
  <small><%= link_to '(Synchronise...)', synchronise_dictionaries_path, :onclick => "#{update_page {|page| page.show(:progress_bar)}}" %></small>&nbsp;
  <span id="progress_bar" style="display:none;">
    <%= image_tag('progress_bar.gif', :border => 0, :width => 120) %>
  </span>  
<% end %>

<p>
  <ul>
    <% if @dictionaries.empty? %>
      <%= no_model_found Dictionary.class_name %>
    <% else  %>
      <%= render :partial => @dictionaries %>
    <% end %>
  </ul>
</p>
<%= will_paginate @dictionaries %>
<br>
<div id="definitions"></div>